﻿function fnToggle(a,b){
	var id="oImgShow"+a;
	$("#oImgShowBigPic").attr("src",$("#"+id).attr("src"));
	$("#oImgShowBigPic").attr("rel",$("#"+id).attr("rel"));
	$("#oTransContainer").attr("rel",id);
	$("#tabImageSmall > li").each(function(i){
		$("#tabImageSmall > li")[i].className=((i+1)==a)?"zwpicshowCur":"";
	})
	if (b=="a"){
		if (a>($("#tabImageSmall > li").length-2)){a=$("#tabImageSmall > li").length-2}
		if (a<4){a=2}
		var marginNum=-((a-2)*102-24)
		$("#tabImageSmall").css("top",marginNum+"px")
	}
}
function f(a){
	var ElemntShowPnum=$('#oTransContainer').attr("rel").replace('oImgShow','');
	if (ElemntShowPnum){
		var tempNum=Number(ElemntShowPnum)+a
		if (tempNum>$("#tabImageSmall > li").length) tempNum=1
		if (tempNum<1) tempNum=$("#tabImageSmall > li").length
	}
	fnToggle(tempNum,"a")
}
	$(function(){	
		 $("#PsrollPicShowDiv").imageScroller({
				next:"leftarr",
				prev:"rightarr",
				frame:"isl_cont2",
				width:958,
				child: "li",
				auto: true
			});	
			
		    $(".jqzoom").jqueryzoom({
		        xzoom:200,  // 放大图的宽
		        yzoom:200,  // 放大图的高
		        offset:10,   // 放大图距离原图的位置
		        position:'right'  // 放大图在原图的右边(默认为right)
		    });
	var e = new opCard();
		e.bind = ["zhengwenMenu","a","zhengwenCont","blockquote"];
		e.style = ["","contCurrent",""];
		e.overStyle = true;
		e.creat();
		e = null;
	
	var e2 = new opCard();
		e2.bind = ["zhengwenMenu1","a","zhengwenCont1","blockquote"];
		e2.style = ["","contCurrent",""];
		e2.overStyle = true;
		e2.creat();
		e2 = null;
	});